<!DOCTYPE html>
<html>
<head>
  <title></title>
  <script src="resources/jquery.js"></script>
  <link rel="stylesheet" href="css/main.css">
  <link rel="stylesheet" href="css/menu.css">
  <link rel="stylesheet" href="css/common.css">
  <link rel="stylesheet" href="css/header.css">

  <meta charset="UTF-8">
</head>
<?php
/**
 * Created by PhpStorm.
 * User: Aliaksei Lazerka
 * Date: 10/17/14
 * Time: 10:27 PM
 */
include_once("elems/header.php");
include_once("elems/menu.php");
include_once("functions/db_manipulate.php");

$sections = getAllSections();
?>

<body>
<div class="sectionsFullDiv">
  <?php
  while ($section = mysql_fetch_assoc($sections)) {
    ?>
    <div class="sectionDiv" style="background-image: url('img/<?= $section['IMG'] ?>')">
      <div class="sectionDivFakeBackground commonTextInDivCenter"
           onclick="location.href='?cat&sid=<?= $section['ID'] ?>'">
        <?= $section['TITLE'] ?>
      </div>
    </div>
  <?php
  }
  ?>
</div>
</body>
</html>